﻿<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head >
    <title>SVG_WebGIS_Demo</title>    
    <link rel="stylesheet" href="./css/layout.css" type="text/css" />
    <script language="javascript" type="text/javascript">   
    
    var svgDocument = null;
    
    function Init()
    {
        svgDocument = document.getElementById("mapObject").getSVGDocument();
        
        aa.style.top = mapContainer.style.top;
        aa.style.left = mapContainer.style.left;
        aa.style.width = mapContainer.style.width;
        aa.style.height = mapContainer.style.height;
    }
    
    function SetCurrentOperation(operName)
    {   
        svgDocument.documentElement.setAttribute("attrib:operation",operName);
      
        aa.style.cursor = "hand";
    }
    
    function GetSource()
    {
        alert( svgDocument.data);
    }
    
    function  SetMapFullExtent() {};
    
    </script>
</head>

<body onload="Init()"> 
    <div>
    <div style="background-color:ThreeDShadow;width: 700px; height: 100px">
    <!--<img src="" alt="SVG_WebGIS_Demo" style="width: 501px; height: 46px" />-->
    <h1 style="color:Blue;">SVG WEBGIS</h1> 
    </div>       
            <div id="tools">
                <img src="image/zoomin.png" alt="地图放大" onclick="SetCurrentOperation('ZoomInByRect')"/>
                <img src="image/zoomout.png"  alt="地图缩小" onclick="SetCurrentOperation('ZoomOutStep')"/>
                <img src="image/fullextent.png" alt="全图" onclick="SetMapFullExtent()"/>
                <img src="image/pan.png" alt="地图平移" onclick="SetCurrentOperation('Pan')"/>
                <input type="button" onclick="SetCurrentOperation('ZoomInByClick')" />
                </div>
            <div id="mapContainer" style="width: 700px; height: 600px;">
            <script src="./js/loadSVGCtrl.js" language="javascript"></script>
            </div>
    </div>    
    <div style="width: 700px; height: 100px;">
    <label style="color:Purple"> All copyright reversed by lionyue</label>
   <p></p>
   <div id="infos"></div>
    </div>
    <div id="aa" style="z-index:1000;background: #FF6633; position:absolute; -moz-opacity:0.5; filter:alpha(opacity=50);"></div>
</body>
</html>
